package com.xr.pfm.demo.pfming;

import com.xr.common.CommUtil;
import com.bstek.dorado.data.*;
import com.bstek.dorado.common.*;

/**
 * datasetNewMsgListener
 */
public class datasetNewMsgListener extends AbstractDatasetListener {
  public boolean beforeLoadData(Dataset dataset)
     throws Exception {

    return true;
  }

  public void afterLoadData(Dataset dataset)
     throws Exception {
	  dataset.moveFirst();
	  while(!dataset.isLast()){
		  CommUtil.executeUpdate("update pfm_dialog set is_read=1 where PFM_DIALOG_ID="+dataset.getString("PFM_DIALOG_ID"));
		  dataset.moveNext();
	  }


  }

}
